package wy.controller;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;
import java.util.Map;

/**
 * @描述
 * @创建人 wangyue
 * @创建时间2020/12/816:10
 */
@FeignClient(value = "my-user",fallback = ShopServiceImpl.class)
public interface ShopService{

    @GetMapping("/shop/getAll")
    public List<Shop> getAll();

    @PostMapping("/shop/save")
    public void save(@RequestBody Shop shop);

    @GetMapping("/shop/getById/{id}")
    public Shop getById(@PathVariable(value = "id") Integer id);

    @PostMapping("/shop/pageList")
    public Map<String,Object> pageList(@RequestBody final Shop shop, @RequestParam("pageSize") int pageSize,@RequestParam("pageNum") int pageNum);
}
